package org.wx.ormtest.init;

import java.io.FileInputStream;
import java.io.IOException;
import java.util.Properties;

/**
 * @description:Properties 助手
 * @author: wangxun
 * @createDate: 2021/3/2
 * @version: 1.0
 */
public class PropertiesHelper {
    static Properties properties = new Properties();
    static {
        try {
            properties.load(new FileInputStream(PropertiesHelper.class.getClassLoader().getResource("config.properties").getPath()));
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

    public static String get(String key) {
        return properties.getProperty(key);
    }
}
